<template>
  <page-form :x-uri="uri" :custom-components="custom">
    <!-- 自定义tab -->
    <template v-slot:page-tabs>
      <tabs :course-id="courseId" :tabs="tabs" />
      <page-header :content="headerTitle" />
    </template>
  </page-form>
</template>

<script>
import PageForm from '@public/template/page_form.vue';
import Tabs from '../tabs';
import PageHeader from '@/components/page-header';
import Choose from './choose'
export default {
  components: {
    PageForm,
    Tabs,
    PageHeader
  },
  data() {
    return {
      uri: '/course/admin/exam/' + this.$route.params.id + '/create',
      headerTitle: '添加试卷',
      tabs: [
        {
          title: '添加试卷',
          uri: '/course/exam/' + this.$route.params.id + '/create'
        }
      ],
      custom: {
        paper_id: Choose
      }
    };
  },
  computed: {
    courseId() {
      return this.$route.params.id
    }
  }
};
</script>
